package com.heima.test1;

import java.util.ArrayList;

public  class StudentUtil {
    private static ArrayList<Student> list = new ArrayList<>();
    public static void addStudent(Student student){
        list.add(student);
    }
    public static void printStudent(){
        for (int i = 0; i < list.size(); i++) {
            Student student = list.get(i);
            System.out.println("姓名"+student.getName()+"年龄"+student.getAge()+"学号"+student.getId());
        }
    }
}
